import store from '../store'

//累加action
export const incrementAction=(data)=>{
    return {
        type:'increment',
        data
    }

    
}

//累减action
export const decrementAction=(data)=>{
    return {
        type:'decrement',
        data
    }

    
}
//异步action

export const waitIncrementAction =(data)=>{
    return()=>{
        setTimeout(()=>{
            store.dispatch({
                type:'increment',
                data
            })
        },2000)
    }
} 